from vec import Vec2
import math
WIDTH = 500
HEIGHT = 500

PEN_COLOR = (0, 200, 0)
BACK_COLOR = (0, 0, 0)

pt_a = Vec2(250, 100)
len = 100
h = 100 / 2 * math.sqrt(3)
pt_d = Vec2(pt_a.x, pt_a.y + h)
pt_b = Vec2(pt_d.x - 50, pt_d.y)
pt_c = Vec2(pt_d.x + 50, pt_d.y)

def draw():
    screen.fill(BACK_COLOR)
    
    screen.draw.line(pt_a.raw_get(), pt_b.raw_get(), PEN_COLOR)
    screen.draw.line(pt_b.raw_get(), pt_c.raw_get(), PEN_COLOR)
    screen.draw.line(pt_c.raw_get(), pt_a.raw_get(), PEN_COLOR)